package app.server.project.main.service.dto.withdraw;

import com.fasterxml.jackson.annotation.JsonIgnore;
import lombok.Data;

@Data
public class WithDrawReq {
    private int raceId;
    /**
     * 钱包地址
     */
    private String walletUrl;
    /**
     * 金额
     */
    private String amount;

    public static void main(String[] arg) {
        String cai = "0.00000000001";
        System.out.println(Double.parseDouble(cai) * 1000000000000L);
    }

    @JsonIgnore
    public long getAmountLong(long rate) {
        return (long) (Double.parseDouble(this.amount) * rate);
    }
}
